package com.dwxt.cdms.dao;

import com.dwxt.cdms.entity.Customer;
import com.dwxt.cdms.entity.EquipmentCustom;
import com.dwxt.cdms.view.EquipmentCustomView;
import com.dwxt.cdms.vo.SelectEquipmentCustomVo;
import org.apache.ibatis.annotations.Param;
import tk.mybatis.mapper.common.Mapper;

import java.util.List;

public interface EquipmentCustomMapper extends Mapper<EquipmentCustom> {

    EquipmentCustomView selectEquipmentCustomById(String id);

    List<EquipmentCustomView> selectEquipmentCustomList(SelectEquipmentCustomVo selectVo);

    int updateDistributionStatusToZeroByEquipmentCustomIds(@Param("ids") String[] ids);

    int deleteEquipmentCustomByIds(@Param("ids") String[] ids);

    EquipmentCustom selectEquipmentCustomByDeviceIdentity(String deviceIdentity);

    int deleteEquipmentCustomByEquipmentId(String equipmentId);

    int selectEquipmentCustomCount(EquipmentCustom equipmentCustom);

    int deleteEquipmentCustomByCustomerIds(@Param("ids") Integer[] ids);

    int updateDistributionStatusToZeroByCustomIds(@Param("ids")Integer[] ids);

    EquipmentCustom selectByEquipmentId(@Param("equipmentId")String equipmentId);

    List<EquipmentCustom> selectByCustomerId(@Param("id")Integer id);

    List<EquipmentCustomView> selectBindLbWatchList();

    Customer selectCustomerBySerialNumber(@Param("serialNumber") String serialNumber);

    String selectLbUseridByCustomerId(@Param("customerId") Integer customerId);
}